-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: 오토레이아웃 편의 Anchor 함수 작성 #37
Conversation
top: view.safeAreaLayoutGuide.topAnchor, | ||
leading: view.leadingAnchor, | ||
bottom: view.safeAreaLayoutGuide.bottomAnchor, | ||
trailing: view.trailingAnchor |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
top과 bottom은 safeAreaLayoutGuide로 했습니당
괜찮을까요 ??
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
좋아욤!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
둏습니다!! 역시 팀장님...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
정말 수고 많으셨습니다 .ᐟ.ᐟ 👍 남긴 코멘트들이 모두 P3라서 Approve를 했는데, merge시키기 전 한 번 확인해주시면 감사하겠습니당 .ᐟ.ᐟ
func setHorizontal(view: UIView, constant: CGFloat) { | ||
self.translatesAutoresizingMaskIntoConstraints = false | ||
self.setLeading(anchor: view.leadingAnchor, constant: constant) | ||
self.setTrailing(anchor: view.trailingAnchor, constant: constant) | ||
} | ||
|
||
func setHorizontal(layoutGuide: UILayoutGuide, constant: CGFloat) { | ||
self.translatesAutoresizingMaskIntoConstraints = false | ||
self.setLeading(anchor: layoutGuide.leadingAnchor, constant: constant) | ||
self.setTrailing(anchor: layoutGuide.trailingAnchor, constant: constant) | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
P3: 위 두 함수는 각각 어떻게 다른건가요?? 레이아웃 가이드만 넣어야하고, UIView만 넣어야하는 경우가 각각 따로 있나요??
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
아래 코드를 의도하고 만들긴 했습니다 !
layoutGuide의 경우 불 필요할까요 ??
titleLabel.setVertical(layoutGuide: view.safeAreaLayoutGuide, constant: 20)
or
titleLabel.setVertical(view: view, constant: 20)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
옹 저런 경우가 있을 수 있겠군요 .ᐟ.ᐟ 저는 저런 이유라면 남겨도 될 것 같다는 의견입니다 .ᐟ.ᐟ
MemorialHouse/MHPresentation/MHPresentation/Source/Extensions/UIView+Anchor.swift
Outdated
Show resolved
Hide resolved
Co-authored-by: 00me <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
고생하셨습니다 ❕
#️⃣ 연관된 이슈
📝 작업 내용
📒 리뷰 노트
Before
After